def dem(m,n):
    a = [0] * 25
    used = [m, n]
    def backtacking(step):
        if step == m + n + 1:
            for i in range(1, m + n + 1):
                print(a[i], end='')
            print()
        for i in range(2):
            if used[i] > 0:
                a[step] = i
                used[i] -= 1
                backtacking(step + 1)
                used[i] += 1

    backtacking(1)


m, n = map(int, input().split())
dem(m,n)

